package com.easylinkin.linkappapi.deviceattribute.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;

import java.io.Serializable;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 设备属性租户个性化配置
 * </p>
 *
 * @author TongJie
 * @since 2020-10-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("linkapp_device_attribute_tenant_config")
@ApiModel(description = "设备属性租户配置实体类")
public class DeviceAttributeTenantConfig extends Model<DeviceAttributeTenantConfig> {

    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @TableId("id")
    @ApiModelProperty(value = "主键ID", required = false, example = "")
    private String id;

    /**
     * 租户id
     */
    @TableField("tenant_id")
    @ApiModelProperty(value = "租户ID", required = false, example = "")
    private String tenantId;

    /**
     * 设备属性id
     */
    @TableField("device_attribute_id")
    @ApiModelProperty(value = "设备属性ID", required = false, example = "")
    private String deviceAttributeId;

    /**
     * 属性名称
     */
    @TableField(exist = false)
    @ApiModelProperty(value = "属性名称", required = false, example = "")
    private String deviceAttributeName;

    /**
     * 型号id
     */
    @TableField(exist = false)
    @ApiModelProperty(value = "型号ID", required = false, example = "")
    private String deviceUnitId;

    @TableField(exist = false)
    @ApiModelProperty(value = "旧设备属性ID", required = false, example = "")
    private String oldDeviceAttributeId;

    /**
     * 排序
     */
    @TableField("sort_no")
    @ApiModelProperty(value = "排序号", required = false, example = "0")
    private Integer sortNo;

    /**
     * 是否默认显示,默认不显示，0-不显示，1-显示
     */
    @TableField("is_show")
    @ApiModelProperty(value = "是否默认显示", required = false, example = "")
    private Boolean isShow;


    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
